package com.kevin.controller;

import com.dtflys.forest.springboot.annotation.ForestScan;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.scheduling.annotation.EnableAsync;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;

@EnableAsync
@EnableScheduling
@SpringBootApplication(scanBasePackages = {"com.kevin"})
@MapperScan(basePackages = {"com.kevin.**.mapper"})
@ForestScan("com.kevin.service.forest")
public class KevinApplication {

    public static void main(String[] args) {
        SpringApplication.run(KevinApplication.class, args);
    }

    @Bean
    public BCryptPasswordEncoder passwordEncoder() {
        return new BCryptPasswordEncoder();
    }

}
